package com.chinasofti.io;

import java.io.FileReader;
import java.io.FileWriter;
import java.io.IOException;

public class Demo08 {
    public static void main(String[] args) throws IOException {
        FileReader fr = new FileReader("java419\\a.txt");
        // int read()
//         int ch;
//         while((ch=fr.read()) != -1){
//             System.out.print((char)ch);
//         }
        char[] chs = new char[1024];
        int len;
        while((len=fr.read(chs)) != -1){
            System.out.println(new String(chs,0,len));
        }

        fr.close();
    }
}
